package entity;

public class Student {

    private String name;
    private int age;
    private float weight;
    private static double PI = 3.14;

    public String sex;
    protected double score;

    /**
     * 构造方法 - Construct
     */
    public Student() {
    }

    public Student(String naeme,int age ,float weight) {
        this.name = naeme;
        this.age = age;
        this.weight = weight;
    }

    public Student(String name, Float weight) {
        this.name = name;
        this.age = 18;
        this.weight = weight;
    }


    private Student(String name) {
        this.name = name;
        this.age = 18;
        this.weight = 100;
    }

    /**
     * 方法 - Method
     *
     * @return
     */
    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public float getWeight() {
        return weight;
    }

    public void setWeight(float weight) {
        this.weight = weight;
    }

    public void hello() {
        System.out.println("你好!");
    }

    private String sleep(String address, int hour) {
        System.out.printf("睡觉了 - 地点：%s - 时长：%d", address, hour);
        return "睡饱了得好好学习，天天向上！";
    }

    public void sayHello(String who) {
        System.out.println("你好," + who);
    }

    public void sayHello(String who, int age) {
        System.out.println("你好," + who);
    }

    public int sum(int i, int j) {
        return i + j;
    }
public String add (String name){

        return "这里添加";
}
    @Override
    public String toString() {
        return this.getName() + "," + this.getAge() + "," + this.getWeight();
    }

    public static boolean isLeapYear(int year){
        return (year % 4 == 0 && year % 100 != 0) || (year % 400 == 0);
    }
    /**
     * 静态方法
     */
    public static void study() {
        System.out.println("学习!");
    }

    public static void study(String sth) {
        System.out.printf("学习《%s》", sth);
    }
}
